#ifndef ARTIST_H
#define ARTIST_H

/**
Nectarine Utility Project is a software interface for the web system 'demovibes'
Copyright (C) 2010  Alexandre LAURENT

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.

website: http://code.google.com/p/nectarine-utility-project/
e-mail: lw.demoscene@gmail.com
**/

#include <QList>
#include <QString>
#include <QUrl>

#include <QDebug>

#include "group.h"
#include "song.h"
#include "status.h"

class QXmlStreamReader;

typedef struct Artist
{
    unsigned int id;
    QString nickname;
    QString realname;
    QUrl website;
    QString flag;
    QList<struct Group> groups;
    Status status;
    QString location;
    QString info;
    QString twitter;
    QString lastfm;
    QString aliasOf;
    QList<QString> aliases;
    QList<struct Song> songs;

    Artist(void):id(0),nickname(""),realname(""),website(QUrl("")),flag(""),status(S_INACTIVE),location(""),info(""),twitter(""),lastfm(""),aliasOf("") {}
}Artist;

QDebug operator<<(QDebug dbg, const Artist& ai);

bool parseArtist(QXmlStreamReader& xmlReader, Artist& a);
bool parseArtistPage(QXmlStreamReader& xmlReader, Artist& a);
bool readArtistPage(const QByteArray& streamData, Artist& a);

#endif // Artist_H
